
# Table of Contents

1.  [lilu-debugger: debugging utilities](#org49317fa)
    1.  [Usage](#org898a1b3)
        1.  [Debugging](#org7299960)
        2.  [Breaking](#orgccb4ff6)
    2.  [Installation](#org712daea)
    3.  [Implemented Debuggers](#org78c2001)
    4.  [Author](#orge6153fd)
    5.  [Copyright](#org8c90725)
    6.  [License](#orga691a9c)


<a id="org49317fa"></a>

# lilu-debugger: debugging utilities


<a id="org898a1b3"></a>

## Usage


<a id="org7299960"></a>

### Debugging

To install the debugger hook:

    (enable-debugger)

To ensure it is installed globally:

    (enable-debugger :force-global-p t)

To uninstall it

    (disable-debugger)
    ;; (disable-debugger :force-global-p t)

To activate a debugger (e.g. emacs):

    (setf (active-debugger) :emacs)

To get the list of installed debuggers:

    (registered-debuggers)

To get the active debugger:

    (active-debugger)

To set a default-debugger (e.g. emacs):

    (setf *default-debugger* :emacs)

to use it:

    (setf (active-debugger) :default)

or:

    (setf (active-debugger) :dynamic) ;; it check *default-debugger* at every invocation

To use a degugger locally (e.g. emacs):

    (with-debugger (:emacs)
      ...
      )

To ignore condition (inside with-debugger):

    (with-debugger (:emacs)
      ...
      (ignore-conditions
        ...
        )
      ...
      )


<a id="orgccb4ff6"></a>

### Breaking

To install the debugger hook for the break function:

    (enable-break)

To ensure it is installed globally:

    (enable-break :force-global-p t)

To uninstall it

    (disable-break)
    ;; (disable-debugger :force-global-p t)

To activate a specific debugger for break (e.g. emacs):

    (setf (active-break-debugger) :emacs)

To set **break-on-signals**:

    (with-break-on-signals (:emacs)
      ...
      )

or:

    (with-debugger (:emacs 'warn)
      ...
      )


<a id="org712daea"></a>

## Installation

Clone the project into local-projects of quicklisp, then

    (ql:quickload :lilu-debugger)

Load different debugger implementation:

    (ql:quickload :lilu-debugger/emacs) ;; require lilu-emacs
    (ql:quickload :lilu-debugger/clim)  ;; require mcclim
    (ql:quickload :lilu-debugger/dmenu) ;; require lilu-dmenu


<a id="org78c2001"></a>

## Implemented Debuggers

<table border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">


<colgroup>
<col  class="org-left" />

<col  class="org-left" />

<col  class="org-left" />

<col  class="org-left" />
</colgroup>
<thead>
<tr>
<th scope="col" class="org-left">Name</th>
<th scope="col" class="org-left">What</th>
<th scope="col" class="org-left">Requires</th>
<th scope="col" class="org-left">Quicklisp</th>
</tr>
</thead>

<tbody>
<tr>
<td class="org-left">:none</td>
<td class="org-left">do nothing</td>
<td class="org-left">&#xa0;</td>
<td class="org-left">s</td>
</tr>


<tr>
<td class="org-left">:abort</td>
<td class="org-left">always invoke abort restart</td>
<td class="org-left">&#xa0;</td>
<td class="org-left">&#xa0;</td>
</tr>


<tr>
<td class="org-left">:quit</td>
<td class="org-left">always exit from common lisp</td>
<td class="org-left">&#xa0;</td>
<td class="org-left">&#xa0;</td>
</tr>


<tr>
<td class="org-left">:default</td>
<td class="org-left">see <b>defaul-debugger</b></td>
<td class="org-left">&#xa0;</td>
<td class="org-left">&#xa0;</td>
</tr>


<tr>
<td class="org-left">:dynamic</td>
<td class="org-left">see <b>default-debugger</b> at every invocation</td>
<td class="org-left">&#xa0;</td>
<td class="org-left">&#xa0;</td>
</tr>


<tr>
<td class="org-left">:emacs</td>
<td class="org-left">open emacs and run its debugger</td>
<td class="org-left">lilu-emacs</td>
<td class="org-left">No</td>
</tr>


<tr>
<td class="org-left">:lem</td>
<td class="org-left">open lem and run its debugger</td>
<td class="org-left">mcclim</td>
<td class="org-left">Yes</td>
</tr>


<tr>
<td class="org-left">:clim</td>
<td class="org-left">&#xa0;</td>
<td class="org-left">lilu-lem</td>
<td class="org-left">No</td>
</tr>


<tr>
<td class="org-left">:dmenu</td>
<td class="org-left">use dmenu to select a debugger</td>
<td class="org-left">lilu-dmenu</td>
<td class="org-left">No</td>
</tr>
</tbody>
</table>


<a id="orge6153fd"></a>

## Author

-   Alessandro Serra (gas2serra@gmail.com)


<a id="org8c90725"></a>

## Copyright

Copyright (c) 2021 Alessandro Serra (gas2serra@gmail.com)


<a id="orga691a9c"></a>

## License

Creative Commons CC0 1.0 Universal

